import React from 'react'
import { useNavigate } from 'react-router-dom'
function ItemList({v}) {
    let navigate=useNavigate()
   const gotoxq=(id)=>{
   navigate(`/xq/${id}`,{state:id})
   }

  return (
    <div>
      <dl onClick={()=>gotoxq(v.id)}>
        <dt>
            <h1>{v.title}</h1>
            <h2>{v.title}</h2>
            <h3>{v.data}</h3>
            <h3>{v.price}</h3>
        </dt>
        <dd>
            <img style={{width:"100%",height:"300px"}} src={v.image} alt="" />
        </dd>
      </dl>
    </div>
  )
}

export default ItemList
